import React from 'react';
import { Pagination } from 'antd';
const Page = (props) => {
     // 切换页数的时候触发
     const onChange = (page) => {
        props.setPage(page)
    }
    return (
         <div>
            <Pagination defaultCurrent={props.page} current={props.page} total={props.total} onChange={(page) => onChange(page)} />
        </div>
    );
}

export default Page;
